import request from '@/utils/request'
export const getRoleListAPI = (params) => request.get('/park/sys/role', { params })

export const getTreeListAPI = () => request.get('/park/sys/permision/all/tree')

export const getRoleDetailAPI = (roleId) => request.get(`/park/sys/role/${roleId}`)

export const getRoleUserAPI = (roleId) => request.get(`/park/sys/roleUser/${roleId}`)

export const createRoleUserAPI = (data) => request.post(`/park/sys/role`, data)

export const updateRoleAPI = (data) => request.put(`/park/sys/role`, data)

export const delRoleUserAPI = (roleId) => request.delete(`/park/sys/role/${roleId}`)
